﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Data;

namespace Code_Group3.WEBFORM
{
    public partial class Main : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                BUS.AccountBUS accBUS = new BUS.AccountBUS();
                Data.Card cardObj = new Data.Card();
                cardObj.CARDID = Session["CardID"].ToString();
                DataTable dt = accBUS.GetAcc(cardObj);
                Session["Balance"] = dt.Rows[0]["Balance"].ToString();
                Session["NameCus"] = dt.Rows[0]["NameCus"].ToString();
                Session["AccountID"] = dt.Rows[0]["AccountID"].ToString();
                lblAccountName.Text = Session["NameCus"].ToString();
            }
        }

        protected void Button1_Click(object sender, EventArgs e)
        {
            Response.Redirect("Withdraw.aspx");
        }
        protected void Button3_Click(object sender, EventArgs e)
        {
            Response.Redirect("CashTransfer.aspx");
        }

        protected void Button5_Click(object sender, EventArgs e)
        {

        }

        protected void btn1_Click(object sender, EventArgs e)
        {
            
        }
    }
}